<%@ page import="java.sql.*, database.*"%>
<%

DBCon db = new DBCon();

String data = "";
String value;
value = request.getParameter("choose_project")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='choose_project'");
else
    db.setControl("value ='true' where name ='choose_project'");

value = request.getParameter("professor_reg")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='professor_reg'");
else
    db.setControl("value ='true' where name ='professor_reg'");

value = request.getParameter("student_reg")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='student_reg'");
else
   db.setControl("value ='true' where name ='student_reg'");

value = request.getParameter("professor_login")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='professor_login'");
else
    db.setControl("value ='true' where name ='professor_login'");

value = request.getParameter("student_login")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='student_login'");
else
    db.setControl("value ='true' where name ='student_login'");

value = request.getParameter("assign_project")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='assign_project'");
else
    db.setControl("value ='true' where name ='assign_project'");

value = request.getParameter("professor_update")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='professor_update'");
else
    db.setControl("value ='true' where name ='professor_update'");

value = request.getParameter("student_update")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='student_update'");
else
    db.setControl("value ='true' where name ='student_update'");

value = request.getParameter("project_add")+"";
if(value.equals("null"))
    db.setControl("value ='false' where name ='project_add'");
else
    db.setControl("value ='true' where name ='project_add'");

value = request.getParameter("project_update")+"";
if(value.equals("null"))
   db.setControl("value ='false' where name ='project_update'");
else
    db.setControl("value ='true' where name ='project_update'");

value = request.getParameter("control_project")+"";
if(value.equals("null"))
   db.setControl("value ='false' where name ='control_project'");
else
    db.setControl("value ='true' where name ='control_project'");

value = request.getParameter("change_gpa")+"";
if(value.equals("null"))
   db.setControl("value ='false' where name ='change_gpa'");
else
    db.setControl("value ='true' where name ='change_gpa'");

response.sendRedirect("controlSite.jsp");

%>